<!DOCTYPE html>
<html lang="zh-CN">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- 上述3个meta标签*必须*放在最前面，任何其他内容都*必须*跟随其后！ -->
    <title>lesson3</title>

    <!-- Bootstrap -->
    <link href="/app/bower_components/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
    <link href="/lesson3/css/app.css" rel="stylesheet">
    <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
      <script src="//cdn.bootcss.com/html5shiv/3.7.2/html5shiv.min.js"></script>
      <script src="//cdn.bootcss.com/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
  </head>
  <body ng-app="app" ng-strict-di>
    <div class="container">
      <h1>第三课</h1> 
      <hr>
      <div ng-controller="TestCtrl as test">
        <button class="btn btn-default" ng-click="test.showBoxOne = !test.showBoxOne">Toggle Box One</button>
        
        <div class="box-one" ng-show="test.showBoxOne">
          Hello! I am <b>box one</b>.
        </div> 
      </div> 
      <hr>
      <div ng-controller="TestCtrl as test">
        <button class="btn btn-default" ng-click="test.showBoxOne = !test.showBoxOne">Toggle Box One</button>
        
        <div class="box-two" ng-show="test.showBoxOne">
          Hello! I am <b>box two</b>.
        </div> 
      </div> 
      <hr> 
      <div ng-controller="Test2Ctrl as test">
        <button class="btn btn-default" ng-click="test.people.push({name:'Steve Jobs'})">Add item to ng-repeat</button>
        <button class="btn btn-primary" ng-click="test.people.pop()">Remove item from ng-repeat</button>
        <div class="item" ng-repeat="person in test.people">
          {{ person.name }}
        </div>
      </div> 
      <hr>
      <div ng-controller="Test3Ctrl as test">
        <button class="btn btn-default" ng-click="test.bigger = !test.bigger">
          Set bigger = {{ !test.bigger }}
        </button>
        <button class="btn btn-default" ng-click="test.lightTheme = !test.lightTheme">
          Set lightTheme = {{ !test.lightTheme }}
        </button>
        <div class="box" ng-class="{ 'bigger': test.bigger, 'light-theme': test.lightTheme }">
          This is just a box.
        </div>
      </div> 
      <hr>
      <div>

      </div>       
    </div>
    <script src="/app/bower_components/angular/angular.min.js"></script>
    <script src="/app/bower_components/angular-animate/angular-animate.min.js"></script>
    <script src="/lesson3/js/app.js"></script>
    <!-- <script src="/lesson2/js/services.js"></script> -->
    <!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
    <script src="/app/bower_components/jquery/dist/jquery.min.js"></script>
    <!-- Include all compiled plugins (below), or include individual files as needed -->
    <script src="/app/bower_components/bootstrap/dist/js/bootstrap.min.js"></script>
  </body>
</html>